const AWS = require('aws-sdk');
const regions = require("../../common/awsRegions");
AWS.config.update({region: regions.region_ap_southeast_1});

const sts = new AWS.STS();

const d = {};

d.getCallerIdentity = (params) => new Promise((resolve, reject) => {
  sts.getCallerIdentity(params, function(err, data) {
    if (err) {
      reject(err);
    } // an error occurred
    else {
      resolve(data);
    }// successful response
  });
});


module.exports = d;